﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
using Timer = System.Windows.Forms.Timer;

namespace WinFormswork2
{
    public partial class LoadingForm : Form
    {
        private Timer timer;
        public LoadingForm()
        {
            InitializeComponent();

            timer = new Timer();
            timer.Interval = 3000; // 3秒
            timer.Tick += new EventHandler(timer_Tick);
            timer.Start();
        }

        void timer_Tick(object sender, EventArgs e)
        {
            timer.Stop(); // 停止计时器
            this.DialogResult = DialogResult.OK; // 可以选择用不同的方式关闭窗口
        }
        private void LoadingForm_Load(object sender, EventArgs e)
        {
            
        }
    }
}
